$(function() {

IndexBannerSlide();

});

//幻灯
var c = 0;
var s = 0;
var clock;
function IndexBannerSlide() {
c = $("#divbanner li").size();
bannermouseover();
bannerlist();
}
function bannerAutoShow() {
if (s >= c) {
s = 0;
}
$("#divbanner li ").removeClass();
$("#divimagebanner a").filter(":visible").hide();
$("#divbanner li").eq(s).addClass('current');
$("#divimagebanner a").eq(s).show();
s++;
}
function bannerlist() {
clock = window.setInterval("bannerAutoShow()", 5000);
}
function bannermouseover() {
$("#divbanner li").each(function(index) {
$(this).bind("mouseover", function() {
$("#divbanner li ").removeClass();
$("#divimagebanner a").filter(":visible").hide();
$("#divbanner li").eq(index).addClass('current');
$("#divimagebanner a").eq(index).show();
window.clearInterval(clock);
});
$(this).bind("mouseout", function() {
clock = window.setInterval("bannerAutoShow()", 5000);
});
});
}
